package com.mzy.basics.system;

import com.alibaba.fastjson.JSON;
import com.mzy.model.ResponseDTO;

import java.util.UUID;

/**
 * @author Ives
 * * @date 2021/12/27
 */
public class systemDemo {
  public static void main(String[] args) {
    StringBuilder stringBuilder = new StringBuilder();
    System.out.println(stringBuilder.append(UUID.randomUUID().toString().substring(0, 8)));
    String abc = System.setProperty("abc", "123");
    String property = System.getProperty("abc");
    System.out.println(property);
    System.out.println(JSON.toJSONString(System.getenv(),true));

    ResponseDTO<String> demo = demo();

    System.out.println(JSON.toJSONString(demo));
  }

  public static ResponseDTO<String> demo(){
    return ResponseDTO.ok("测试");
  }
}
